Waits for a function to return true (waits for 1 sec by default).
Running in browser context.

```js
I.waitForFunction(fn[, [args[, timeout]])
```

```js
I.waitForFunction(() => window.requests == 0);
I.waitForFunction(() => window.requests == 0, 5); // waits for 5 sec
I.waitForFunction((count) => window.requests == count, [3], 5) // pass args and wait for 5 sec
```

@param {string|function} fn to be executed in browser context.
@param {any[]|number} [argsOrSec] (optional, `1` by default) arguments for function or seconds.
@param {number} [sec] (optional, `1` by default) time in seconds to wait
@returns {void} automatically synchronized promise through #recorder
